package myimport;

import org.springframework.cglib.proxy.InvocationHandler;

import java.lang.reflect.Method;

public class ProxyHandler implements InvocationHandler {

    private Object object;

    public ProxyHandler(Object object) {
        this.object = object;
    }

    @Override
    public Object invoke(Object o, Method method, Object[] objects) throws Throwable {
        System.out.println("proxy before method");
        method.invoke(object, objects);
        System.out.println("proxy after method");
        return null;
    }
}
